import Vue from 'vue'
import VueRouter from 'vue-router'
import designer from '@/components/formDesigner'
// import dialogTest from '@/pages/dialogTest'
// import queryDialogTest from '@/pages/queryDialogTest'
// import view from '@/pages/view'
import home from '@/pages/home'
import main from '@/pages/main.vue'
import modular from '@/pages/modular'
import dataManage from '@/pages/dataManage'
import fromlist from '@/pages/fromlist'
import dictTable from '@/pages/dictTable'
import maplist from '@/pages/maplist'
import flowData from '@/pages/flowData'
// import makeTable from '@/pages/makeTable'
// import showText from '@/pages/showText'
// import sortTable from '@/pages/sortTable'
// import filteTable from '@/pages/filteTable'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'home',
    component: home,
    meta: { title: '应用设计器', index: 0 }
  }, {
    path: '/modular',
    name: 'modular',
    component: modular,
    meta: { title: '模块管理', index: 1 }
  },
  {
    path: '/modular/fromlist',
    name: 'fromlist',
    component: fromlist,
    meta: { title: '表单管理', index: 2 }
  }, {
    path: '/modular/dictTable',
    name: 'dictTable',
    component: dictTable,
    meta: { title: '字典管理', index: 2 }
  }, {
    path: '/modular/maplist',
    name: 'maplist',
    component: maplist,
    meta: { title: '地图管理', index: 2 }
  }, {
    path: '/modular/dataManage',
    name: 'dataManage',
    component: dataManage,
    meta: { title: '数据配置', index: 3 }
  },
  {
    path: '/designer',
    name: 'designer',
    component: designer,
    meta: { title: '表单设计', index: 3 }
  },
  {
    path: '/flowData',
    name: 'flowData',
    component: flowData,
    meta: { title: '流程图', index: 3 }
  },
]

const router = new VueRouter({
  routes
})

export default router
